package com.plan.dao.service.card.impl;

import com.plan.controller.card.request.PointLogPageListReq;
import com.plan.dao.mapper.card.PointLogMapper;
import com.plan.dao.service.card.PointLogDaoService;
import com.plan.entity.card.PointLog;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import javax.annotation.Resource;
import java.util.List;

@Service
public class PointLogDaoServiceImpl implements PointLogDaoService {
    @Resource
    private PointLogMapper pointLogMapper;

    @Override
    public List<PointLog> getPointLogPageList(PointLogPageListReq req) {
        return pointLogMapper.getPointLogPageList(req);
    }

    @Override
    @Transactional(rollbackFor = Exception.class)
    public void realDeleteByCardId(Long teamId, Long cardId) {
        int num = pointLogMapper.realDeleteByCardId(teamId, cardId);
    }
}
